import { Component, type ReactNode } from "react";

import style from "./index.module.css";

interface IProps {
  title: string;
  children: ReactNode;
}

export default class Card extends Component<IProps> {
  render() {
    return (
      <div className={style.box}>
        <div className={style.top}>{this.props.title}</div>
        <div className={style.body}>{this.props.children}</div>
      </div>
    );
  }
}
